<?php

namespace backend\models\course;

use Yii;

/**
 * This is the model class for table "{{%edu_course_order_info}}".
 *
 * @property integer $info_id
 * @property integer $order_id
 * @property integer $course_id
 * @property string $course_name
 * @property integer $course_type
 * @property string $price
 */
class CourseOrderInfo extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return '{{%course_order_info}}';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['order_id', 'course_id', 'course_name', 'price'], 'required'],
            [['order_id', 'course_id', 'course_type'], 'integer'],
            [['price'], 'number'],
            [['course_name'], 'string', 'max' => 255]
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'info_id' => 'Info ID',
            'order_id' => 'Order ID',
            'course_id' => 'Course ID',
            'course_name' => 'Course Name',
            'course_type' => 'Course Type',
            'price' => 'Price',
        ];
    }
}
